<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>

    <div><input type="text" value="dmc1"></div>
    <div><input type="text" value="dmc2"></div>
    <div><input type="text" value="dmc3"></div>

    <script src="../d3.js"></script>
    <script>
        const inputSelection = d3.selectAll('input');
        //console.log(inputSelection.attr('value'));

        //inputSelection.attr('value','DMC') ;
      
        // inputSelection.data(['dmc','duyi','harbin']).attr('value',(d,i,nodes)=>{
        //     return d ;
        // })


        // d3.selectAll('div')
        //     .data(['red','green','blue'])
        //     .style('margin','10px')
        //     .style('padding','10px')
        //     .style('width','200px')
        //     .style('border','1px solid #ccc')
        //     .style('background',function(d){
        //         return d;
        //     })

        // d3.selectAll('div').text('<li>')

         d3.selectAll('div').on('click',function(e,d){
            console.log(arguments,this);
         })   

    </script>
</body> 
</html>